package com.gkwave.ui;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;


public class TransportHome extends Activity implements OnClickListener{

	private static final String TAG = "TransportHome";

	private Button mBusRegiter = null;
	private Button mCabRequest = null;
	private Button mSearch = null;
	private Button mFeedback = null;
	
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.transport);
		
		mBusRegiter = (Button) findViewById(R.id.btn_busregister);
		mCabRequest = (Button) findViewById(R.id.btn_cabrequest);
		mSearch = (Button) findViewById(R.id.btn_search);
		mFeedback = (Button) findViewById(R.id.btn_feedback);
		
		mBusRegiter.setOnClickListener(this);
		mCabRequest.setOnClickListener(this);
		mSearch.setOnClickListener(this);
		mFeedback.setOnClickListener(this);
	}
	
	public void onClick(View arg0) {
		int id = arg0.getId();
		Intent intent = new Intent();
		switch(id){
		case R.id.btn_busregister:
			intent.setClass(this, BusRegister.class);
			startActivity(intent);
			break;
		case R.id.btn_feedback:
			intent.setClass(this, Feedback.class);
			startActivity(intent);
			break;
		case R.id.btn_cabrequest:
			intent.setClass(this, CabRequest.class);
			startActivity(intent);
		default: break;
		}
	}

}
